Last Updated 10/28/2022

Sage Essentials
Section 4: Solving Equations

The find_root and roots command

Example 2

For polynomial equations of the form f( x )=0 . We can use the roots command to find its numerical solutions. For example, to find the solutions of 2 x 6 +3 x 5 +3 x 3 2 x 2 =0 , we first define the function f( x ) , follows by the roots command.

 

 

The output is in the format of (root, multiplicity).

Try this!

For the function f defined above, find the solutions of f ( x )=0 . [Hint: Define the derivative function as fp(x)=diff(f(x),x)]

 


← Previous Example Next Example →